'''
整理数据
'''
from common.config import *
from db.mysql import MysqlClient
from common.helper import Helper
class Arrangement( object ):
    def __init__(self):
        self.name = "人保寿险关爱心脑血管疾病保险"
        self.mysql = MysqlClient()
    def pullData(self, data={}):
        for item in Helper.selectData(self.name, self.mysql):
            data["name"] = self.name
            data["company"] = "中国人民保险"
            data["year"] = item["year"]
            data["gender"] = "1"
            data["expire"] = "1年"
            data["payType"] = "年交"
            data["majorDisease"] = "10w"
            data["slightDisease"] = "0" if item["slightDisease"] == "0" else "2w"
            data["price"] = item["price"]
            Helper.mergeTable( self.name,self.mysql,data )
